﻿using System;
using Ext.Net;

namespace CourseManager.View.UControls
{
	public partial class Header : System.Web.UI.UserControl
	{
		protected void Page_Load(object sender, EventArgs e)
		{

		}

		protected void LogoutEvent(object sender, DirectEventArgs e)
		{
			if(Session["UserId"] != null)
			{
				//Util.AddLog(Session["UserId"].ToString(), "Logout");
				Session["UserId"] = null;
			}
			Response.Redirect("Login.aspx");
		}

		protected void LockEvent(object sender, DirectEventArgs e)
		{
			lockWindow.ShowModal();
			lockWindow.Hidden = false;
		}
	}
}